<template>
	<view class="centers">
		<h1>{{list.name}}</h1>
		<rich-text :nodes="list.content" space="emsp" class="centertext" />
	</view>
</template>

<script>
	export default {
		data() { 
			return {
				list:[],
			}
		},
		onLoad(options) {
			const id=options.id
			this.getlist(id)
		},
		methods: {
			async getlist(id){
			const list	=await	uni.$http.get('/cantlogin/getNewsByid',{id})
			if(list.statusCode!==200) return uni.$showMsg()
			this.list=list.data
				},
		}
	}
</script>

<style>
	.centers {
		padding: 20rpx;
		background-color: #feeeed;
	}

	.centers .img {
		width: 90%;
		margin: 30rpx auto;
	}

	.centers .img image {
		width: 100%;
	}

	h1 {
		font-weight: 900;
		font-size: 35rpx;
		text-align: center;

	}

	.centertext {
		line-height: 120rpx;
		font-size: 32rpx;
		letter-spacing:5rpx;
	}
</style>
